import request from '@/utils/request'

export function checkAnswerFromApi(interview) {
  return request({
    url: '/ai/daily_tasks/stream/check_answer',
    method: 'get',
    params: {
      question:interview.question,
      answer:interview.answer,
    }
  })
}


// 查询每日任务列表
export function queryDailyInterviewList(date,interviewType,classesId) {
  return request({
    url: '/teaching/daily_tasks/list/interview',
    method: 'get',
    params: {
      date,
      interviewType,
      classesId
    }
  })
}
// 查询每日任务列表
export function listDaily_tasks(query) {
  return request({
    url: '/teaching/daily_tasks/list',
    method: 'get',
    params: query
  })
}

// 查询每日任务详细
export function addDailyTasks(dailyTask) {
  return request({
    url: '/teaching/daily_tasks/',
    method: 'post',
    data: dailyTask
  })
}

// 新增每日任务
export function addDaily_tasks(data) {
  return request({
    url: '/teaching/daily_tasks',
    method: 'post',
    data: data
  })
}

// 修改每日任务
export function updateDaily_tasks(data) {
  return request({
    url: '/teaching/daily_tasks',
    method: 'put',
    data: data
  })
}

// 删除每日任务
export function delDaily_tasks(id) {
  return request({
    url: '/teaching/daily_tasks/' + id,
    method: 'delete'
  })
}
